package com.drawu.drawuspring.controller;


import com.drawu.drawuspring.domain.DTO.ActivitiesDto;
import com.drawu.drawuspring.domain.DTO.MessageDto;
import com.drawu.drawuspring.domain.Result;
import com.drawu.drawuspring.domain.VO.MessageVo;
import com.drawu.drawuspring.service.IActivitiesService;
import com.drawu.drawuspring.service.IMessageService;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.*;

import java.util.List;

/**
 * <p>
 *  前端控制器
 * </p>
 *
 * @author hui
 * @since 2025-04-01
 */

@RestController
@RequestMapping("/message")
@RequiredArgsConstructor
@Tag(name = "消息", description = "消息相关接口")
public class MessageController {

    private final IMessageService messageService;

    @Operation(summary = "创建活动")
    @PostMapping("/send")
    public Result<MessageDto> sendMessage(@RequestBody MessageDto messageDto) {
        return Result.success(messageDto);
    }

    @Operation(summary = "获取自己的所有消息")
    @GetMapping("/get")
    public Result getMessages() {
        return messageService.getMessages();
    }
}
